package com.ewancle.proxydownload.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

// 2. 图片压缩配置 - ImageCompressionConfig.java
@Configuration
@ConfigurationProperties(prefix = "image.compression")
public class ImageCompressionConfig {
    private int quality = 80;
    private int maxWidth = 1920;
    private int maxHeight = 1080;
    private String format = "JPEG";
    private boolean progressive = true;

    // getters and setters
    public int getQuality() { return quality; }
    public void setQuality(int quality) { this.quality = quality; }

    public int getMaxWidth() { return maxWidth; }
    public void setMaxWidth(int maxWidth) { this.maxWidth = maxWidth; }

    public int getMaxHeight() { return maxHeight; }
    public void setMaxHeight(int maxHeight) { this.maxHeight = maxHeight; }

    public String getFormat() { return format; }
    public void setFormat(String format) { this.format = format; }

    public boolean isProgressive() { return progressive; }
    public void setProgressive(boolean progressive) { this.progressive = progressive; }
}